#app {
  --card-w: 80px;
  --card-h: 100px;
}
.card-box {
  position: relative;
  width: var(--card-w);
  height: var(--card-h);
  overflow: hidden;
  background: #c9c9c9;
  font-size: 0;
}
.card-box .card {
  position: absolute;
  left: 0;
  width: var(--card-w);
  height: calc(var(--card-h) / 2);
  line-height: var(--card-h);
  text-align: center;
  user-select: none;
  font-size: 81px;
  color: #212121;
  overflow: hidden;
  transition: all 0.5s;
}

.card-box .card-top {
  top: 1px;
  background: #d64242;
  z-index: 10;
}

.card-box .card-bottom {
  top: 50%;
  line-height: 0;
  background: #5456d4;
  transform-origin: center top;
  transform: rotateX(0deg);
  backface-visibility: hidden;
}
